Method of initializing an optical encoder

ABSTRACT

A method of initializing the position of an optical shaft encoder without having to precisely index the encoder with respect to its shaft. The optical encoder includes an optical shutter mounted for rotation with the shaft and light emitters and light detectors associated with the optical shutter for respectively illuminating and detecting a predetermined pattern of code markings formed on the optical shutter. An electrical circuit, such as a suitably programmed microprocessor, is responsive to the status of the light emitters and light detectors for determining the angular position of the optical shutter and shaft relative to the light emitters and detectors from the detected predetermined pattern. The optical shutter is mounted to the shaft in some arbitrary position and the code pattern associated with this position is detected by the electrical circuit. This position is then used as the &#34;zero&#34; or index position and all other angular positions of the optical shutter and shaft are thereafter indexed to this initial position. This eliminates the need to align the optical shutter with some indexing mark on the shaft or with a shaft driven pointer, such as utilized in the dial-type register display commonly used in gas, water or electric meters.

CROSS REFERENCE TO RELATED APPLICATIONS

This application contains subject matter related to co-pendingapplications Ser. No. 650,031, filed Sept. 13, 1984, entitled "OpticalShaft Encoder", and Ser. No. 650,151, filed Sept. 13, 1984, entitled"Method and Apparatus for Detecting Tampering With a Meter Having anEncoded Register Display", which are assigned to the assignee of thepresent application.

BACKGROUND OF THE INVENTION

The present invention relates to the field of optical shaft encoders,and more particularly to a method for initializing the position of anoptical encoder with its associated shaft.

Optical shaft encoders are well known for their use in determining theangular position of a rotating shaft. Such optical shaft encoders areused in various types of machinery and machine tools where informationconcerning the precise angular relationship between a shaft and anothercomponent is needed.

Optical shaft encoders generally consist of an optical shutter, such asa disk or drum, which is rigidly attached to the shaft whose position isto be determined. The optical shutter is used to modulate thetransmission of light between a light emitter (e.g. a light emittingdiode) and a light detector (e.g. a photodiode or phototransistor). Thismodulation may be transmissive, in which case the optical shutter has apattern of slots formed on its surface and the light emitter and lightdetector are arranged on opposite sides of the optical shutter.Alternatively, the modulation may be reflective, in which case theoptical shutter has a pattern of reflective (e.g. white) and absorptive(e.g. black) areas on its surface and the light emitter and lightdetector are arranged adjacent one another on the same side of theoptical shutter.

In general, the resolution of a optical shaft encoder depends on thenumber of light emitting and light detecting devices used. For example,using one emitter and one detector, whose output will be either a "1"(on) or "0" (off), will give an angular resolution of 1/2 a revolutionof the shaft. If two emitters and two detectors are used, the detectoroutputs can have up to four different states (e.g. 00, 01, 10, or 11)and thus will be able to resolve 1/4 of a revolution. Three emitters andthree detectors can have eight different states and resolve 1/8 of arevolution; four emitters and four detectors can have sixteen differentstates and resolve 1/16 of a revolution, etc.

In co-pending application Ser. No. 650,031, filed Sept. 13, 1984,entitled "Optical Shaft Encoder" an optical shaft encoder is disclosedwhich utilizes an optical shutter, such as a disk or drum, mounted to ashaft and having a pattern of light transmissive and lightreflective/absorptive areas formed thereon. A first light emitter and afirst light detector are arranged on one side of the optical shutter anda second light emitter and a second light detector are arranged on theopposite side of the optical shutter facing the first light emitter anddetector. Through an appropriate choice of the patterns of lighttransmissive and reflective/absorptive areas formed on the opticalshutter, and by alternately energizing the light emitters, up to 16different angular positions of the optical shutter and shaft withrespect to the light emitters and light detectors may be resolved.

Optical shaft encodes of the foregoing types have been proposed for usein detecting the position of the shafts which drive a clock-dial typeregister display such as used in a gas, water, or electricity meter.Such a display usually consists of a dial face similar to that used on aclock and having the numerals 0-9 printed thereon. A pointer isremovably attached to each shaft, and each shaft is in turn linked tothe metering mechanism of the meter. The shaft and pointer are normallyrotated by an amount that is proportional to the amount of billablecommodity (e.g. gas, water, electricity) being monitored by the meter.

One problem associated with the use of such prior art optical encoderswith meter display registers is the necessity of indexing (i.e.positioning) the optical shutter with respect to a predetermined shaftposition or with respect to the position of the dial-pointer carried bythe shaft. For example, the pointers of meter dial registers arenormally set at zero at the factory before being shipped to a customer.With prior art arrangements, the code markings associated with the"zero" position of the optical shutter would have to be positionedprecisely adjacent the light emitters and light detectors and theoptical shutter then locked or otherwise fixed in position with respectto the pointer shaft. Obviously, such initializing or indexing is timeconsuming and prone to errors which can result in erroneous readingsbeing generated by the optical encoder.

SUMMARY OF THE INVENTION

The present invention concerns a method of initializing the position ofan optical shaft encoder regardless of its actual position with respectto its associated shaft. The method is useful in conjunction with anoptical shaft encoder of the type including an optical shutter mountedfor rotation with a shaft, light emitter means and light detector meansassociated with the optical shutter for respectively illuminating anddetecting a predetermined pattern of code markings formed on the opticalshutter, and electrical circuit means responsive to the status of thelight emitter means and light detector means for determining the angularposition of the optical shutter relative to the light emitter means andlight detector means from the detected predetermined pattern. Inparticular, the method concerns initializing the predetermined patternrelative to an arbitrary shaft and optical shutter position andcomprises the steps of storing, in an electrical memory means associatedwith the electrical circuit means, a predetermined pattern of electricalsignals corresponding to each different set of code markings formed onthe optical shutter associated with the particular angular position ofthe shaft and optical shutter, setting the shaft and optical shutter atsome arbitrary angular position relative to the light emitter means andlight detector means, detecting the particular set of code markingsassociated with the arbitrary angular position of the shaft and opticalshutter, and assigning a predetermined position value to the detectedarbitrary angular position and incrementally different position valuesto remaining angular positions.

With the foregoing method, the optical shutter need not be aligned inany particular position with respect to the shaft, but rather the lightemitter means and light detector means are utilized to detect the codemarkings on the optical shutter when in some initial arbitrary positionwith respect to its associated shaft. The electrical circuit means isthen caused to index all the other predetermined angular positions ofthe optical shutter and shaft with respect to this initial position.

The initialization method may further include the step of storing thepredetermined pattern of electrical signals corresponding to eachdifferent set of code markings formed on the optical shutter in anonvolatile memory coupled to the electrical circuit means. In this way,the initial position of the optical shutter and the arbitrary valuesassigned to this initial position, and the other positions indexed withrespect thereto, will be maintained in the event that power is lost tothe electrical circuit means.

The initialization method may be used to initialize a plurality ofoptical shutters, each being mounted to a separate shaft. In thisarrangement the electrical circuit means is responsive to light emittermeans and light detector means associated with each such opticalshutter. The initialization of each optical encoder proceeds asdescribed above with the initialized angular position values for eachoptical encoder being stored by the electrical circuit means in theelectrical memory means.

BRIEF DESCRIPTION OF THE DRAWING FIGURES

These and other features and advantages of the present invention will bereadily apparent from the following description of the preferredembodiments of the invention and as shown in the accompanying drawingfigures wherein:

FIG. 1 is a perspective view of a first embodiment of an optical shaftencoder constructed in accordance with the principles of the presentinvention;

FIGS. 2a and 2b are plan views of the inside and outside, respectively,of the optical shutter shown in FIG. 1 illustrating the patterns oflight transmissive and light reflective areas formed thereon, and FIG.2c is a chart illustrating the coding scheme represented by the patternsof FIG. 2a and 2b;

FIG. 3 is a perspective view of an alternative embodiment of an opticalshaft encoder constructed in accordance with the principles of thepresent invention;

FIGS. 4a and 4b are plan views of the front and rear, respectively, ofthe optical shutter shown in FIG. 3 illustrating the patterns of lighttransmissive and light reflective areas formed thereon;

FIG. 5 is a schematic diagram of circuitry utilized in conjunction withthe optical encoders shown in FIGS. 1 and 3;

FIG. 6 is an exploded perspective view of a clock-dial register displayshowing the use of a plurality of optical encoders such as shown in FIG.1; and

FIG. 7 is a cross-section of the register display shown in FIG. 6 takenalong plane 7--7.

DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

FIG. 1 shows an optical encoder useful for practicing the initializationscheme of the present invention. The optical encoder includes an opticalshutter 1 mounted to a shaft 3 for rotation therewith. As shown in FIG.1, optical shutter 1 takes the form of a cylinder or drum. Opticalshutter 1 includes a pattern of light transmissive areas 5 and lightreflective and absorptive areas 7a and 7b, respectively, formed alongthe cylindrical surface thereof. As used herein, the term "reflective"is intended to mean areas having a reflectivity to light varying between0% (i.e. totally absorptive) to 100% (i.e. totally reflective).

Also associated with the optical shutter are a first light emitter E1and a first light detector D1, arranged adjacent one another within thecylinder defined by optical shutter 1, and a second light emitter E2 anda second light detector D2 arranged adjacent one another and oppositethe first light emitter and light detector, E1 and D1, outside thecylinder defined by the optical shutter. Light emitters E1 and E2 maybe, for example, light emitting diodes, while light detectors D1 and D2may be, for example, photodiodes or phototransistors.

As shown in FIG. 1, the optical axes of detector D1 and emitter E2 arealigned with each other. Likewise the optical axes of light emitter E1and detector D2 are aligned with each other.

FIGS. 2a and 2b show the inside and outside, respectively, of thecylinder forming optical shutter 1 as it would appear if broken alongthe line labeled 2--2 in FIG. 1 and unrolled. This illustrates theparticular pattern of light transmissive areas 5 and light reflectiveand light absorptive areas 7a and 7b formed on the inside and outsidesurfaces of optical shutter 1.

As shown in FIG. 2c, if light emitters E1 and E2 are alternatelyenergized, the output of light detectors D1 and D2 will depend upon Etheparticular pattern of light transmissive and light reflective/absorptiveareas which are positioned adjacent the first and second light emittersand light detectors. For example, in the position corresponding to thetopmost areas of FIGS. 2a and 2b (labeled "a" in FIG. 2c), when thefirst light emitter E1 is turned on there will be an output from thefirst light detector D1 (defined to be a "1") because light from emitterE1 will be reflected by light reflective area 7a back to detector D1.However, there will be no output generated by detector D2 (defined to be"0") because the solid portions of optical shutter 1 block the lightfrom emitter E1 from reaching detector D2.

Likewise, when light emitter E2 is energized, there will be an outputfrom detector D2 due to the light being reflected from reflective area7a, but no output from detector D1 because of the solid portion of theoptical shutter prevents light from emitter E2 from reaching detectorD1.

In the next position (labeled "b" in FIG. 2c), when light emitter E1 isenergized there will be an output produced at detector D1 due to lightreflecting off reflective area 7a. In addition, light from emitter E1will travel through light transmissive area 5 to be detected by detectorD2. When light emitter E2 is energized, however, only light detector D2will be energized due to light reflecting off area 7a. The solid portionof optical shutter 1 disposed between light emitter E2 and lightdetector D1 prevents any light from reaching detector D1.

In the next position (labeled "c" in FIG. 2c), when light emitter E1 isenergized there will be an output produced at detector D1 due to lightreflecting off area 7a. Also, light from emitter E1 will travel throughlight transmissive area 5 to be detected by detector D2 when lightemitter E2 is energized. However, neither detector D1 nor D2 will beenergized because the solid light absorptive area 7b between emitter E2and detector D1 prevents any light from reaching detector D1 or frombeing reflected back to detector D2. The outputs of light detectors D1and D2 for the remaining positions (d-j) along optical shutter 1 areshown in FIG. 2c.

The bit patterns shown in FIG. 2c, corresponding to predeterminedangular positions of optical shutter 1 with respect to the lightemitters and light detectors, can be readily detected and correlated byelectrical circuitry, such as shown in FIG. 5, which is discussed inmore detail below.

It will be appreciated that while 10 different positions are shown asbeing encoded in FIGS. 2a-2c (corresponding to an angular resolution of36°), up to 16 positions may be encoded (corresponding to an angularresolution of 22.5°) using only two light emitters and two lightdetectors and an appropriate combination of light reflective/absorptiveand transmissive areas arranged on the optical shutter. This is becausea total of 4 bits of information (e.g. the two different outputsavailable from detectors D1 and D2 based on the alternate energizationof emitters E1 and E2) are available. This results in a total of 2⁴ =16unique states the outputs of detectors D1 and D2 can take in conjunctionwith the status ("on" or "off") of light emitters E1 and E2.

Preferably, the particular pattern of light transmissive and lightreflective/absorptive areas provided on optical shutter 1 are selectedso that movement of the optical shutter relative to the pairs of lightemitters and light detectors from one position to the next results inonly one bit changing in the output pattern of detectors D1 and D2 (seeFIG. 2c). This type of encoding scheme is called Gray coding. This typeof encoding scheme has the advantage that since only one bit changesbetween each adjacent angular position, any other bit changes (such asif two bits change simultaneously) can be considered to be spurious.However, other types of encoding schemes may be utilized withoutdeparting from the basic principles of the invention.

FIG. 3 shows an alternative embodiment for the optical encoder in whichthe optical shutter takes the form of a disk 11 mounted to a shaft 13,with the disk having a pattern of light transmissive areas 15 and lightreflective and absorptive areas, 17a and 17b respectively, formedthereon. Light emitter E1 and light detector D1 are arranged adjacentone another on one side of disk 11, while light emitter E2 and lightdetector D2 are arranged adjacent one another on the opposite side ofdisk 11 with the optical axis of emitter E1 and being aligned with thatof detector D2 and the optical axis of emitter E2 being aligned withthat of detector D1.

FIG. 4a shows the pattern of light transmissive and lightreflective/absorptive areas on the front of disk 11 (also seen in FIG.3). FIG. 4b illustrates the pattern provided on the opposite side ofdisk 11. As in the arrangement shown in FIGS. 1 and 2a-2c, lightemitters E1 and E2 are alternately energized and the outputs ofdetectors D1 and D2 change state in accordance with the particularangular position of disk 11 relative to the pairs of light emitters andlight detectors. The particular pattern shown in FIGS. 4a and 4b isanalogous to the pattern shown in FIGS. 2a and 2b, i.e. the outputs ofdetectors D1 and D2 will follow a Gray code pattern as code disk 11 isrotated past the light detectors while the light emitters are beingalternately energized.

FIG. 5 shows one type of circuit which may be utilized for energizinglight emitters E1 and E2 and detecting the outputs of light detectors D1and D2. The circuit comprises a microprocessor 100 and a random accessmemory (RAM) 110 connected thereto. Microprocessor 100 includes at leasta pair of outputs 120 and 130 which are connected to light emitters E1and E2, respectively. Microprocessor 100 further includes a pair ofinputs 140 and 150 connected to the outputs of light detectors D1 andD2, respectively.

It will be appreciated that microprocessor 100 is merely exemplary ofone type of control circuitry which may be utilized in practicing thepresent invention. The microprocessor or control circuitry merely needsto have suitable input/output ports or connections for receiving thesignals from light emitters D1 and D2 and for outputting control signalsto light emitters E1 and E2. The microprocessor or control circuitryshould also be capable of handling at least a four bit word. Not shownin FIG. 5 are such things as power supplies, ground connections, a clockand input/output buffering circuits, all of which are well known andneed not be described here.

Microprocessor 100 is suitably programmed, such as through instructionsstored in RAM 110 to cause the microprocessor to alternately energizelight emitters E1 and E2 via signals supplied along lines 120 and 130,respectively, and to receive and detect the presence or absence ofoutput signals from light detectors D1 and D2 along lines 140 and 150,respectively. RAM 110 includes a preprogrammed pattern corresponding toall the possible states of lines 120, 130, 140 and 150 (i.e. the statesof light emitters E1 and E2 and light detectors D1 and D2) whichcorrespond to predetermined positions of the optical shutter withrespect to the light emitters and light detectors. For example, apattern such as shown in FIG. 2c may be stored in RAM 110.Microprocessor 100 compares the various outputs and inputs along thelines 120, 130, 140 and 150 to determine which one of thesepredetermined patterns is present. Microprocessor 100 then generates anoutput signal at 160 having a value which is indicative of which one ofthese predetermined patterns, representing a particular angular positionof the shaft and optical shutter, has been detected. This output signalmay be binary, binary coded decimal, ASCII or of other conventionaltype. The output signal can be displayed or transmitted for utilizationby other suitable computing devices. For example, if the optical encoderis to detect the position of the dial pointer in a meter displayregister (such as shown in FIG. 6), output 160 of microprocessor 100 maybe used to electrically encode the dial reading for subsequent readingby the utility or for transmission to suitable meter reading orrecording devices located at a site remote from the meter location.

The particular details of programming microprocessor 100 would, ofcourse, depend upon the particular microprocessor employed, and would bewithin the ordinary skill of one familiar with the operation of suchmicroprocessors. In addition, while the programming instructions andshaft-position representative patterns have been described as beingpresent in RAM 110, it will be appreciated that these instructions andpatterns may be embedded or "burned in" into a permanent memory, such asa read only memory (ROM). In addition, some microprocessor designsinclude within their circuitry a certain amount of RAM and/or ROM sothat a separate memory storage device, such as RAM 110, may be dispensedwith when using such microprocessors.

It will be appreciated that microprocessor 100 may be arranged toreceive the inputs from more than one pair of light detectors and toenergize more than one pair of light emitters. Thus, multiple opticalencoders may be operated by a single microprocessor. The current readingof the position of each optical encoder can be stored in a non-volatilememory so that an interruption of power to the microprocessor or controlcircuitry does not cause this current reading to be lost. The opticalencoder and associated circuitry may be powered through a suitableconnection to an electrical distribution network (such as where theencoder is used in an electricity meter) or it may be powered by meansof a battery or a remote power supply when used in a metering device nothaving its own power source, such as is the case with gas and watermeters.

An important feature of the present invention is that the opticalshutter need not be mounted in any particular relationship to theposition of its associated shaft or with respect to a pointer carried bythe shaft, such as might be used in a dial-type register display (seeFIG. 6 for example). More particularly, the optical shutter is mountedto its associated shaft in some arbitrary position and the lightemitters and light detectors associated therewith are utilized to detectthe particular code markings (the pattern of light transmissive andlight reflective/absorptive areas) which are in proximity to the lightemitters and detectors. This pattern is then recognized bymicroprocessor 100 and is assigned an arbitrary value, such as zero, towhich all other angular positions of the optical shutter and itsassociated shaft are indexed. For example, the optical shutter of FIG. 1may be arbitrarily mounted to its associated shaft with code markingscorresponding to position "e" shown in FIGS. 2a-2c being adjacent thelight emitters and light detectors. The pattern of light detectoroutputs for this position ("1010") is then assigned a value of zero orsome other index value. Code markings associated with position "f" arethen assigned a value of "1", position "g" a value of " 2", etc., withposition "d" being assigned a value of "9".

Of course, if some other position had been the one initially inproximity to the light emitters and light detectors during theinitialization procedure, that position would have been assigned the"zero" or index position. After initialization, the pattern shown inFIG. 2c and the arbitrarily signed values, are preferably stored in anon-volatile memory (either RAM 110 or some other type of non-volatilestorage means). This is so that the initialized position of the opticalshutter will be retained in the event that microprocessor 100 or othercontrol circuitry loses its source of power.

The above initialization method is especially useful when initializing aplurality of optical encoders associated with the shafts of a dial typeregister display, such as is used to display the consumption of gas,water or electricity. Such an arrangement is shown in FIG. 6.

A meter display register 200 includes a faceplate 202 having formedthereon a series of dial type display positions 204a-e. Circular displaypositions 204a-e each have the numerals 0-9 printed about the peripherythereof.

Associated with these these dial positions are dial shafts 206a-e towhich dial pointers 208a-e are removably attached. Dial pointers 208a-einclude a slot which engages respective shafts 206a-e at the point wherethey extend out of faceplate 202 and are secured to the dial shafts bycrimping the slotted ends of the pointers to their associated shafts.

Meter display register 200 further includes a backplate 210 and aclockwork-like mechanism 212 (shown in abbreviated form in FIG. 7)associated with dial shafts 206a-e for rotatably driving the shafts. Adrive shaft 213 (see FIG. 7) is used to drive the clockwork mechanism212 in a well-known fashion in proportion to the amount of a billablecommodity such as gas, water or electricity measured by a suitablemeasuring mechanism, shown generally at 214 in FIG. 6.

Such display registers are normally arranged so that each displayposition 204a-e constitutes one decade of the cumulative value of thequantity being measured by measuring mechanism 214. Thus, position 206emay be assigned to display units, position 204d representing tens, etc.

Associated with shafts 206a-e are optical shutters 214a-e constructed asdescribed above with respect to FIGS. 1 and 2a-2c. Optical shutters214a-e are glued or otherwise fixed attached to their respective shafts206a-e. As described above, optical shutters 214a-e may be fixed in anyarbitrary position with respect to a respective shafts 206a-e, withoutregard to the actual shaft position or that of its associated dialpointer.

A printed circuit board 216 is mounted to the rear of backplate 210 bymeans of a plurality of screws 218 and spacers 220. Printed circuitboard 216 carries the control circuitry, such as shown in FIG. 5, and aplurality of light emitter/light detector packages 222a-e asociated withoptical shutters 214a-e, respective. When assembled together, thepatterned cylindrical surfaces of the optical shutters is positionedbetween the light emitter and light detector units which comprise lightemitter/light detector packages 222a-e (see FIG. 7).

Also mounted to printed circuit board 216 is a light shield 224 whichsurrounds the prephery of light emitter/light detector packages 222a-eand optical shutters 214a-e. Light shield 224 prevents stray light frominterfering with the reading of the code markings on the opticalshutter.

By utilizing the initialization method described earlier, the opticalshutters need not be aligned in any particular position when they aremounted to their respective shafts. They can simply be mounted in anyarbitrary position, the dial pointers 208a-e set to zero, and theparticular position of each optical shutter is then detected andassigned a value of "0" to correspond with the initial setting of thedial pointers.

The above arrangement and technique can be furthe utilized to detecttampering with the meter display register or with the meteringmechanism. One well-known technique for tampering with a meter displayconsists of removing the meter cover and moving the display dialpointers into new positions while the shaft positions remain unchanged.This is usually done so as to indicate a lower amount of the billablecommodity consumed than is actually the case. Such tampering can bereadily detected by the present invention simply by comparing theoutputs of the optical encoders with the quantity proportedly beingdisplayed by their associated mechanical display register. Since opticalencoders 214a-e are permanently attached to their associated shafts206a-e, any physical tampering with the optical encoders usually will beapparent. Further, microprocessor 100 or other control circuitry can beprogrammed to detect if the optical encoder has not moved incrementallyfrom one position to the next. Thus, if an optical shutter is physicallyrotated more than one position away from its current position, suchtampering can be readily detected by the microprocessor or controlcircuitry which can then generate or store a signal indicative of suchtampering.

With certain electricity meters, it is possible to remove the meter fromits socket and mount it upside-down in order to cause the meter to runbackwards, and thus decreasing the display of the amount of electricitybeing consumed. After a certain amount of time, the tamperer then placesthe meter back in its normal upright position. However, this type oftampering can also be detected by the present invention by suitablyprogramming the microprocessor or control circuitry to generate a tamperindicating alarm signal if the direction of rotation of the opticalshutters is not as is expected. This can be done simply by comparing thecurrent value representative of the quantity being displayed by themeter register with the value associated with a measurement made at someprevious time. If the difference is not as is expected (e.g. the currentvalue is less than the previous value) then the tamper indicating alarmsignal is generated.

This tamper indicating signal can be used to illuminate a warning lampor sound an audible alarm. Alternatively, the signal can be stored bythe microprocessor or control circuit and displayed or transmitted onlyupon command of authorized personnel from the utility.

The foregoing description is not intended to be limitative or exhaustivebut rather illustrative of the invention which is defined by theappended claims.

What is claimed is:
 1. In an optical shaft encoder of the type includinga shaft, an optical shutter mounted for rotation with the shaft, lightemitter means and light detector means associated with the opticalshutter for respectively illuminating and detecting a predeterminedpattern of code markings formed on the optical shutter, and electricalcircuit means responsive to the status of the light emitter means andlight detector means for determining the angular position of the opticalshutter and shaft relative to the light emitter means and light detectormeans from the detected predetermined pattern,a method of initializingthe predetermined pattern relative to an arbitrary shaft and opticalshutter position, comprising the steps of:(a) storing, in electricalmemory means associted with the electrical circuit means, apredetermined pattern of electrical signals corresponding to eachdifferent set of code markings formed on the optical shutter associatedwith a particular angular position of the shaft and optical shutter; (b)setting the shaft and optical shutter at some arbitrary angular positionrelative to the light emitter means and light detector means; (c)detecting the particular set of code markings associated with saidarbitrary angular position of the shaft and optical shutter; and (d)assigning a predetermined position value to one of the predeterminedpatterns of electrical signals stored in said memory that corresponds tosaid detected arbitrary angular position and incrementally successiveposition values to remaining successive predetermined patterns.
 2. Themethod of claim 1 wherein step (b) includes the step of storing thepredetermined pattern of electrical signals in a non-volatile memory. 3.The method of claim 1 wherein step (d) said detected arbitrary angularposition is assigned a value of zero.
 4. The method of claim 1 whereinthere are a plurality of shafts and optical shutters, and wherein saidelectrical circuit means is responsive to light emitter means and lightdetector means associated with each such shaft and optical shutter andis arranged to initialize each shaft and optical shutter relative tosome arbitrary angular position.